<template>
  <div class="right-panel">
    <div class="right-header">
      <i class="el-icon-d-arrow-right" @click="close"></i>
      <span>{{ title }}</span>
    </div>

    <div class="right-content">
        <div class="file-list">
          <div class="list-header">
            <div>
              <i class="iconfont icon-wenjianjia" />
              <span>阶段材料</span>
            </div>
            <i class="iconfont icon-shangchuanbeifen"></i>
          </div>
          <el-tree
            :data="list"
            accordion
            @node-click="handleNodeClick"
            :default-expand-all="true"
          >
          </el-tree>
        </div>
        <!-- <div class="file-list">
          <div class="list-header">
            <div>
              <i class="iconfont icon-wenjianjia" />
              <span>相关视频</span>
            </div>
            <i class="iconfont icon-shangchuanbeifen"></i>
          </div>
          <el-tree
            :data="item.Recordlist"
            accordion
            @node-click="handleNodeClick"
            :default-expand-all="true"
          >
          </el-tree>
        </div>
      </div> -->
    </div>
  </div>
</template>
<script>
import { picHost } from "@/settings.js";
export default {
  data() {
    return {
      listContents: {
        市州准备: "市人民政府召开专题推进会",
        区县开会: "区县人民政府召开专题推进会",
        业务培训: "完成动员培训",
        数据分发: "领取底图底数数据及软件",
     
      },
    };
  },
  mounted() {},
  props: {
    title: {
      type: String,
      default: "",
    },
    list: {
      type: Array,
      default: [],
    },
  },
  methods: {
    close() {
      this.$emit("closeRightPanel");
    },
    handleNodeClick(data) {
      window.open(picHost + data.url);
    },
  },
};
</script>
<style lang="scss" scoped>
.right-panel {
  position: fixed;
  right: 0;
  top:55px;
  bottom: 0;
  width: 320px;
  z-index: 9999;
  background-color: #f2f2f2;
  .right-header {
    height: 35px;
    font-size: 18px;
    font-weight: 600;
    background-color: #4778c7;
    color: #fff;
    line-height: 35px;
    i {
      margin-right: 10px;
    }
  }
  .right-content {
    margin: 5px;
    padding: 5px;
    width: calc(100% - 10px);
    height: calc(100% - 45px);
    background-color: #fff;
    overflow-y: auto;
      .title {
        width: 100%;
        line-height: 22px;
        padding-left: 10px;
        margin: 0;
        border-left: 3px solid #4778c7;
        letter-spacing: 1px;
        font-weight: 700;
        border-bottom: 1px dashed #4778c7;
      }
      .list-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        font-size: 14px;
        background-color: #e2e7f0;
        height: 32px;
        line-height: 32px;
        padding: 0 10px;
        span {
          margin-left: 5px;
        }
      }

      .aaa {
        font-size: 14px;
        padding: 10px 0px;
      }
    
  }
}
</style>
